Skip to content

Instantly share code, notes, and snippets.

@jeremy-code
jeremy-code / _Importexport Raycast preferences with GIt history.md
Last active September 13, 2026 04:01
Import/export Raycast preferences with GIt history

Raycast has a feature to import/export preferences in a .rayconfig file format. This isn't ideal for use in a dotfiles-esque Git repository since it would be difficult to compare changes with a compressed file. Also, unfortunately, syncing is only possible on a pro subscription and only through Raycast's cloud service.

To get a more useful JSON file from the .rayconfig (example shown in example.rayconfig.json), you will have to first have to export a decrypted version. Go to Settings > Extensions > Raycast > Export Settings & Data and under "Export Password," which by default is 12345678, you will want to delete that.

After that, run the "Export Settings & Data" command. You should be able to export all of the preferences (Settings, Extensions, Floating Notes, Script Directories, Snippets) except Quicklinks without setting a password.

Then, in terminal, run gzip --decompress --keep --suffix .rayconfig NAME_OF_FILE.rayconfig and you should get a JSON file similar to example.rayconfig.json.

After that,

Deterministic save load in Factorio

One of the key parts of the save/load process in Factorio is that it must be deterministic. This means that for a given save file (when no external factors change) saving, exiting, and loading the save shouldn't change any observable behavior.

There are a few reasons and benefits for this strict requirement:

  • Without it: You couldn't join a running multiplayer game (and by proxy save, exit, and resume one)
  • Without it: the replay system wouldn't work if you ever saved, exited, and resumed playing.
  • With it: we can easily test that saving and loading produces no observable change letting us know we implemented save/load correctly.
  • With it: you won't see things change randomly as a result of "reloading" like you do in so many other games.

LLM Wiki

A pattern for building personal knowledge bases using LLMs.

This is an idea file, it is designed to be copy pasted to your own LLM Agent (e.g. OpenAI Codex, Claude Code, OpenCode / Pi, or etc.). Its goal is to communicate the high level idea, but your agent will build out the specifics in collaboration with you.

The core idea

Most people's experience with LLMs and documents looks like RAG: you upload a collection of files, the LLM retrieves relevant chunks at query time, and generates an answer. This works, but the LLM is rediscovering knowledge from scratch on every question. There's no accumulation. Ask a subtle question that requires synthesizing five documents, and the LLM has to find and piece together the relevant fragments every time. Nothing is built up. NotebookLM, ChatGPT file uploads, and most RAG systems work this way.

@ppworks
ppworks / nginx
Created February 15, 2012 03:04
add nginx configure option "--with-http_gzip_static_module"
require 'formula'
class Nginx < Formula
homepage 'http://nginx.org/'
url 'http://nginx.org/download/nginx-1.0.12.tar.gz'
md5 'd0ceefeb2a68ecb19e78ee894a5b52a3'
devel do
url 'http://nginx.org/download/nginx-1.1.14.tar.gz'
md5 '16d523e395778ef35b49a2fa6ad18af0'
@LuminarLeaf
LuminarLeaf / user-dGPU.ps1
Created September 15, 2024 21:27
Automatically set executables to use specific gpu on Windows
# Script to add executables to Windows Registry to specify which GPU to use
# Tested on Windows 11 23H2 with PowerShell Core 7.4.5, might work on older versions
# Currenly configured as an example to add Java runtimes installed by Minecraft Launcher and ATLauncher to use dGPU
# This script is provided as-is and is not guaranteed to work in all cases
# Use at your own risk
# Possible values for GpuPreference:
# 0: Windows decides which GPU to use
# 1: Low power GPU
@enihsyou
enihsyou / 20-fastfetch.sh
Created August 19, 2025 06:22
Run 'whatever-fetch' on SSH session login
#!/usr/bin/env bash
# shellcheck disable=SC2086
# Run 'whatever-fetch' on SSH session login
# This file is intended to be placed in /etc/update-motd.d/ and
# executed by pam_motd.so upon login (Debian). It may also be placed in /etc/profile.d/
# to run when profile files are loaded; the two differ in execution timing.
# read username from 'sshd-session' process
# https://superuser.com/questions/981897/trying-to-print-username-at-message-of-the-day-motd/1178598#1178598
@xorrior
xorrior / wmic_cmds.txt
Last active September 13, 2026 03:41
Useful Wmic queries for host and domain enumeration
Host Enumeration:
--- OS Specifics ---
wmic os LIST Full (* To obtain the OS Name, use the "caption" property)
wmic computersystem LIST full
--- Anti-Virus ---
wmic /namespace:\\root\securitycenter2 path antivirusproduct
@JoshuaSebastianKim
JoshuaSebastianKim / map.pe.json
Last active September 13, 2026 03:30
Peru map JSON
{
"Lima": {
"Lima": {
"Lima": "150101",
"Ancon": "150102",
"Ate": "150103",
"Barranco": "150104",
"Breña": "150105",
"Carabayllo": "150106",
"Chaclacayo": "150107",
@AKCodez
AKCodez / claude-code-statusline-guide.md
Last active September 13, 2026 03:26
Claude Code Status Line - Complete Guide: all fields, config, ready-to-use scripts

Claude Code Status Line - Complete Guide: all fields, config, ready-to-use scripts

Claude Code Status Line — Complete Guide

A persistent, customizable bar at the bottom of Claude Code that shows real-time session data.

image
@docularxu
docularxu / blog-claude-code-china-zh.md
Last active September 13, 2026 03:18
在中国使用 Claude Code 解决 403 错误 - 完整指南(中文版)

在中国使用 Claude Code 解决 403 错误 - 完整指南(中文版)

在中国使用 Claude Code 解决 403 错误

2026 年 2 月 12 日

如果你在中国尝试使用 Claude Code,大概率会撞上 403 错误。本文覆盖三种使用场景的解决方案:

  • macOS 终端 (shell) - 在终端里直接使用 claude 命令行
  • VS Code 终端 - 在 VS Code 内置终端里使用 claude 命令行